package com.xbongbong.saas.enums;

import com.xbongbong.i18n.util.I18nMessageUtil;
import lombok.Getter;

/**
 * 客户发票信息枚举
 *
 * @author feng.zheng
 * @version v1.0
 * @date 2019/1/28 16:33
 * @since v1.0
 */
@Getter
public enum CustomerInvoiceEnum {
    // 客户发票信息枚举
    /**
     * 抬头类型 @see InvoiceTitleTypeEnum
     */
    TITLE_TYPE("text_1", "enum.customerInvoice.name.title_type", "titleType"),
    TITLE("text_2", "enum.customerInvoice.name.title", "title"),
    TAXPAYER_NO("text_3", "enum.customerInvoice.name.taxpayer_no", "taxpayerNo"),
    REGISTERED_PHONE("text_4", "enum.customerInvoice.name.registered_phone", "registeredPhone"),
    INVOICE_ADDRESS("text_5", "enum.customerInvoice.name.invoice_address", "invoiceAddress"),
    BANK("text_6", "enum.customerInvoice.name.bank", "bank"),
    ACCOUNT("text_7", "enum.customerInvoice.name.account", "account"),
    CUSTOMER_INVOICE_ID("text_8", "enum.customerInvoice.name.customer_invoice_id", "customerInvoiceId"),;

    /**
     * attr
     */
    private String attr;
    /**
     * 名称
     */
    private String name;

    /**
     * saasAttr
     */
    private String saasAttr;


    CustomerInvoiceEnum(String attr, String name, String saasAttr) {
        this.attr = attr;
        this.name = name;
        this.saasAttr = saasAttr;
    }

    public String getName() {
        return I18nMessageUtil.getMessage(name);
    }
}
